package com.googlecode.dgwt.client.dojo.reflect;

import com.googlecode.dgwt.client.dojo.core.JsMap;
import com.googlecode.dgwt.client.dojo.core.JsObject;
import com.googlecode.dgwt.client.dojo.core.NativeWrapper;

/**
 * @author wellsantos@wellsantos.com
 * @since 0.01
 */
public class BeanParam implements NativeWrapper {

    private String name;
    private Class<?> type;
    private String jniSignature;
    
    
    public BeanParam(String name, Class<?> type, String jniSignature) {
        this.name = name;
        this.type = type;
        this.jniSignature = jniSignature;
    }

    public String getName() {
        return name;
    }
    
    public Class<?> getType() {
        return type;
    }
    
    public String getJniSignature() {
        return jniSignature;
    }

    @Override
    public JsObject toJavaScript() {
        JsMap<Object> map = JsMap.create();
        map.set("name", name);
        map.set("type", type);
        map.set("jniSignature", jniSignature);
        return map;
    }

}
